import type { App } from 'vue';

import { vPermission } from '@/directives/permission';

/**
 * 注册全局指令
 * @param app Vue应用实例
 */
export function setupDirectives(app: App) {
  // 注册权限指令
  app.directive('permission', vPermission);
}

// 导出所有指令
export { vPermission, usePermission } from './permission';
